package com.tatada.mvvmdemo.net;

import android.app.Application;
import android.os.Build;

import com.tatada.mvvmdemo.BuildConfig;
import com.toshi.netlib.base.INetworkRequiredInfo;

public class NetInfoInterface implements INetworkRequiredInfo {

    private Application application;

    public NetInfoInterface(Application application) {
        this.application = application;
    }

    @Override
    public String getAppVersionName() {
        return BuildConfig.VERSION_NAME;
    }

    @Override
    public String getAppVersionCode() {
        return String.valueOf(BuildConfig.VERSION_CODE);
    }

    @Override
    public boolean isDebug() {
        return true;
    }

    @Override
    public Application getApplicationContext() {
        return application;
    }
}
